package gofunc

import (
	"context"
)

// GoFunc is the default func used globally.
var GoFunc GoTask

// GoTask is used to spawn a new task.
type GoTask func(context.Context, Runnable)

// Runnable is simple func
type Runnable func()

// Function Represents a function that accepts one argument and produces a result.
type Function func(t any) any

// Consumer Represents an operation that accepts a single input argument and returns no result
type Consumer func(t any)

// Supplier Represents a supplier of results.
type Supplier func() any

// Predicate Represents (boolean-valued function) of one argument.
type Predicate func(t any) bool
